//
//  SLWaterFlowLayout.h
//  SLKit
//
//  Created by S_LINE on 2021/12/29.
//  Copyright © 2021 S_LINE. All rights reserved.
//

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN

@class SLWaterFlowLayout;

@protocol SLWaterFlowLayoutDelegate <NSObject>

- (CGFloat)collectionViewLayout:(SLWaterFlowLayout *)layout heightForItemAtIndexPath:(NSIndexPath *)indexPath;

@end

@interface SLWaterFlowLayout : UICollectionViewFlowLayout

/// 获取item的size信息代理
@property (nonatomic, weak) id<SLWaterFlowLayoutDelegate> delegate;

/// 列数
@property (nonatomic, assign) NSUInteger column;

/// 行间距
@property (nonatomic, assign) CGFloat lineSpacing;

/// 列间距
@property (nonatomic, assign) CGFloat columnSpacing;

/// 内容边距
@property (nonatomic, assign) UIEdgeInsets contentInsets;

/// 每个item的宽度
@property (nonatomic, assign) CGFloat itemWidth;

@end

NS_ASSUME_NONNULL_END
